import * as React from 'react';
import { Switch, withRouter, Redirect } from 'react-router-dom';
import {
    AuthRoute,
    IRouteComponentBaseProps
} from '../../../common';
import List from './List/loadable';

class GraphTypeAreaComponenet extends React.PureComponent<IRouteComponentBaseProps, any> {
    public static displayName = 'WorkerLayout';

    public constructor(props: IRouteComponentBaseProps) {
        super(props);
    }

    public render() {
        return (
            <React.Fragment>
                <Switch>
                    <AuthRoute path="/wk/list" component={List} />
                    <Redirect to="/wk/list" />
                </Switch>
            </React.Fragment>
        );
    }
}

export default withRouter(GraphTypeAreaComponenet);
